#include <iostream>
#include <iomanip>
#include <cmath>
using namespace std;

bool isPrime(int num)
{
  if ((num == 1) || (num == 2))
  {
    return true;
  }

  for (int i = 2; i <= num / 2; i++)
  {
    if (num % i == 0)
      return false;
  }

  return true;
}

int main()
{
  int p1 = 2;
  for (int p = 2; p <= 1000; p++)
  {
    if (isPrime(p))
    {
      if (p - p1 == 2)
        cout << "(" << p1 << ", " << p << ")" << endl;

      p1 = p;
    }
  }

  return 0;
}
